/*-----------------------------------------------------------------------------
 * @file   hal_delay.h
 * @brief  interface for buzy wait by counter or by thread sleep API
 * @author WLH<wanglehui8357@163.com> Copyright (C) 2021~2099.
-----------------------------------------------------------------------------*/
#ifndef HAL_DELAY_H
#define HAL_DELAY_H

#include "globaldef.h"

BEGIN_DECLS

/*-----------------------------------------------------------------------------
 * public functions
-----------------------------------------------------------------------------*/
/**
 * @brief Waits for a specific number of us
 * @param[in]  us The macroseconds
 */
void hal_delay_us(U32 us);

/**
 * @brief Waits for a specific number of ms
 * @note use RTOS delay function to suspend task
 * @param[in]  ms The milliseconds
 */
void hal_delay_ms(U32 ms);

END_DECLS

#endif //~HAL_DELAY_H
